// 设计注册用户页面

// 关闭VSCode非必要的警告
// ignore_for_file: must_be_immutable, non_constant_identifier_names, use_build_context_synchronously, camel_case_types

import 'package:flutter/material.dart';
import 'package:project_award_statistics/utils/my_yaru_buttons/my_yaru_button_error_info.dart';
import 'package:yaru/yaru.dart';

class Dialog_RegisterErrEmpty_Desktop extends StatelessWidget {
  const Dialog_RegisterErrEmpty_Desktop({super.key});

  @override
  Widget build(BuildContext context) {
    return AlertDialog(
      backgroundColor: Theme.of(context).colorScheme.surface,

      // 设置对话框标题样式及文字
      titlePadding: EdgeInsets.all(0),
      title: YaruDialogTitleBar(
        title: Text(
          "注册错误",
          style: TextStyle(
            fontSize: 18,
            fontWeight: FontWeight.bold,
          ),
        ),
        isClosable: false,  // 设置不允许在标题栏关闭,只允许通过按按钮关闭
      ),
      content: SizedBox(
        height: 145,
        width: 450,
        child: Column(   //设置列式布局容器
          children: [
            SizedBox(height: 20,),
            Text(
              "您未输入注册姓名或密码,请重新检查您的输入!",
              style: TextStyle(
                fontSize: 19,
              ),
            ),
            SizedBox(height: 50,),
            SizedBox(
              height: 45,
              width: 200,
              child: MyYaruButton_ErrorInfo(
                text: "好的,我马上去检查", 
                onPressed: ()=>Navigator.of(context).pop(),
              ),
            ),
          ],
        ),
      ),
    );
  }
}
